package com.nami.store.biz.conver.convert;

import com.nami.store.api.request.conversation.ConverAddReq;
import com.nami.store.api.request.conversation.ConverItem;
import com.nami.store.api.response.conversation.ConversationDTO;
import com.nami.store.domain.ConversationDO;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * 会话convert
 *
 * @author lbc@test.com
 * @since 1.0.0 2022-11-29
 */
@Mapper
public interface ConverConvert {

    ConverConvert INSTANCE = Mappers.getMapper(ConverConvert.class);

    /**
     * entity ==> vo
     *
     * @param conversation
     * @return
     */
    ConversationDTO convert(ConversationDO conversation);

    List<ConversationDTO> convertList(List<ConversationDO> conversations);

    ConversationDO convert2(ConverItem converItem);

    List<ConversationDO> converList2(List<ConverItem> conversations);

    ConversationDO convert3(ConverAddReq req);

    List<ConversationDO> convertList3(List<ConverAddReq> requests);

    ConversationDTO convert4(ConverItem converItem);

    List<ConversationDTO> convertList4(List<ConverItem> converItems);

    ConverItem convert5(ConversationDO conversation);

    List<ConverItem> convertList5(List<ConversationDO> conversations);

}






















